<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%--<c:set var="ctx"  value="${pageContext.request.scheme}://${pageContext.request.serverName}:${pageContext.request.serverPort}${pageContext.request.contextPath}" />--%>
<!-- 或者下面的方式 -->
<%--<%--%>
    <%--String path = request.getContextPath();--%>
    <%--String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";--%>
<%--%>--%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
    <meta charset="utf-8" />
    <title>注册报名系统(2017)</title>
    <meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1" />
    <c:set var="ctx" value="${pageContext.request.contextPath}"/>
    <link type="text/css" rel="stylesheet" href="${ctx}/static/css/style.css" />
    <link type="text/css" rel="stylesheet" href="${ctx}/static/css/public.css" />
    <link type="text/css" rel="stylesheet" href="${ctx}/static/css/bglogin.css" />
    <script type="text/javascript" src="${ctx}/static/plugins/jquery/jquery-1.11.3.min.js"></script>
    <%@ include file="/WEB-INF/views/common/easyui.jsp"%>
    <%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
    <script src="${ctx}/static/plugins/My97DatePicker/WdatePicker.js" type="text/javascript"></script>
    <script src="${ctx}/static/plugins/easyui/common/jquery.select.js"type="text/javascript"></script>
</head>
<body id="loginPage">
<form id="loginForm" action="${ctx}/login" method="post">
    <div class="showLogo">
        欢迎使用湖北省"杨威"杯体操冠军赛注册报名系统(2017版)
    </div>
    <div class="loginBox">
        <div class="leftBox">
            <h3>注册报名系统(2017)</h3>
            <div class="login_main_errortip" style="margin-left:75px;margin-top:10px;color:red;"></div>
            <div class="regBox">
                <input type="text" class="inputText"  id="userName" name="userName" autocomplete="off" value="" placeholder="用户名"/>

                <p class="tipsWord right"></p>
                <input type="password" class="inputPassport" id="password" name="password" autocomplete="off" value="" placeholder="密码"/>

                <p class="tipsWord wrong"></p>
                <div>
                    <input type="text" class="yzm" id="
" autocomplete="off" name="captcha" placeholder="验证码" />
                    <img alt="验证码" src="${ctx}/ImageServlet?time=new Date().getTime()" title="点击更换" id="img_captcha"
                         onclick="refreshCaptcha();" style="width:120px; height:34px;"/>
                </div>

                <p class="tipsWord"></p>
                <input class="ibtnentercssclass"
                       style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px"
                       type=image src="${ctx}/static/images/loginImg/btn.jpg">
                </input>

                <p class="tipsWordHi"></p>
                <input type="hidden" class="inputText" >
                    <span id="errorTip" name="errorTip"></span>
                </input>

                <div>
                    <div class="orgRegis"><button><a href="${ctx}/orgRegister_Page">单位注册</a></button></div>
                    <div class="userRegis"><button><a href="${ctx}/userRegister_Page">个人注册</a></button></div>
                </div>
            </div>
        </div>
    </div>
</form>
<script type="text/javascript">
    var msg = '${msg}';
    if(null != msg && ''!=msg && typeof(msg)!="undefined" ){
        $.messager.alert('提示',msg,'info');
    }
    //如果不是顶部，则置顶
    if (window != top){
        top.location.href = location.href;
    }

    //刷新验证码
    function refreshCaptcha()
    {
        document.getElementById("img_captcha").src="${ctx}/ImageServlet?t=" + Math.random();
    }

    //如果有错误会提示，否则提示空
    <%--$("#errorTip").html('${msg}');--%>
</script>
</body>
</html>
